home *** CD-ROM | disk | FTP | other *** search
/ Night Owl 6 / Night Owl's Shareware - PDSI-006 - Night Owl Corp (1990).iso / 026a / formcode.zip / INV.MPG < prev    next >
Text File  |  1991-10-18  |  2KB  |  61 lines

  1. * This is the modified program for INV.FCG. The query statements have been
  2. * added manually in this program. The comments describe the changes that have
  3. * been added. All changes are in lower case. This file gets included in
  4. * INV.PRG each time INV.PRG is generated.
  5. *
  6. * NOTE: This form only uses the COURIER 10 and 12 point fonts to make it
  7. * portable to several different LaserJet printers.
  8. *
  9. SET TALK OFF
  10. SET CONSOLE OFF
  11. * The following line makes all procedures in this file accesible to the main
  12. * program. This line is not necessary for some systems (For example FoxPro).
  13. SET PROCEDURE TO INV
  14. DO FCGINIT
  15. SET PRINT ON
  16. DO FCGSTART WITH 1, 0, 2, 4, 300
  17.  
  18. select 1
  19. use custmers
  20. * The next 2 lines create index file specifically for your system (dBASE, Fox,
  21. * etc). We did not create the index file to make this program portable.
  22. set safety off
  23. index on cust_num to cust_num
  24. select 2
  25. use orders
  26. set relation to cust_num into custmers
  27.  
  28. DO WHILE .not. eof()
  29.     DO FCGFIXOBJ
  30. *   Code for printing table 0.
  31.     FCGTBROW = 0
  32.     mTOTAL = 0
  33.     mCUSTNUM = cust_num
  34.     DO WHILE cust_num = mCUSTNUM
  35.         DO FCGTBRW0 WITH FCGTBROW
  36. *       Do all variable assigmnent, file pointer movement, etc, here.
  37.         FCGTBROW = FCGTBROW + 1
  38.         mTOTAL = mTOTAL + cost
  39.         skip
  40.     ENDDO
  41. *   Make sure all totals fields are up to date at this point
  42.     mAPPREC = "We apraciate our customers!"
  43.     if (mTOTAL > 500)
  44.         mAPPREC = "You are one of our very special customers!!"
  45.     endif
  46.     if (mTOTAL > 1000)
  47.         mAPPREC = "You are one of our best customer!!!"
  48.     endif
  49.     DO FCGTBEN0
  50. *   back up to customer that we were working with so far
  51.     skip -1
  52.     DO FCGVAROBJ
  53.     skip
  54. *   Do all variable re-assignments, file pointer movements, etc, here.
  55.     ?? chr(12)
  56. ENDDO
  57. DO FCGEND
  58. SET PRINT OFF
  59. SET CONSOLE ON
  60. RETURN
  61.